<template>
	<view>
		<web-view :webview-styles="webviewStyles" :src="href"></web-view>
	</view>
</template>
<script setup>
	import {
		onLoad,
		onShow,
	} from "@dcloudio/uni-app";
	import {
		ref,
		reactive
	} from 'vue';
	import {
		useStore
	} from 'vuex';
	const store = useStore()
	let userType = store.state.userType;
	const webviewStyles = ref({});
	const href = ref('');
	onLoad((e) => {
		if (e.type == 'help') {
			href.value =
				`https://www.xuechuangqian.cn/#/waphelp?port=${userType==1?'help_mini_member':'help_mini_company'}`
		}
		if (e.type == 'diy') {
			href.value = uni.getStorageSync('webviewHref');
		}
	})
</script>
<style lang="scss" scoped>
</style>